const odooModelName = 'res.partner'

const values_default = {
  // is_company: true
}

const domain_default = {
  // is_company: true
}

const fields_default = {
  date: null,
  type: null,
  is_company: null,
  function: null,
  display_name: null,
  title: null,
  user_id: null,
  bank_ids: { bank_name: null, display_name: null }
}

const filterItems = ['date', 'name___like', 'type', 'title']

const columns = [
  'country_id__name',
  'state_id__name',
  'is_company',
  // 'function',
  'bank_ids__names',
  'category_id__names',
  'date',
  'title__name',
  'name',
  'email',
  'type__name',
  'display_name',
  'user_id__name',
  'child_ids__count'
]

const table_expand = {
  field: 'bank_ids__objects',
  type: 'table',
  columns: ['display_name', 'bank_name']
}

const formItems = [
  'country_id',
  'state_id',
  'name',
  'email',
  'date',
  'is_company',
  'type',
  'title',
  'category_id'
]

const Model = {
  name: odooModelName,

  configs: {
    values_default,
    domain_default,
    fields_default,
    filterItems,
    columns,
    table_expand,
    formItems
  }
}

export default Model
